<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">

  <head>
    <base href="" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>新增试题</title>
    <!-- web编辑器str -->
    <link rel="stylesheet" href="/lib/kindEditor/themes/default/default.css" />
    <link rel="stylesheet" href="/lib/kindEditor/plugins/code/prettify.css" />
  </head>

  <body>
    <div class="control-group">
      <label class="control-label" style="float:left;"> 试题题目： </label>
      <textarea id="paperTitle" name="paperTitle" cols="100" rows="5" style="width:750px;height:260px;visibility:hidden;float:left;"></textarea>
      <div class="clear"></div>
    </div>
    <script charset="utf-8" src="/lib/jquery/jquery-3.4.1.min.js"></script>
    <script charset="utf-8" src="/lib/kindEditor/kindeditor-all.js"></script>
    <script charset="utf-8" src="/lib/kindEditor/lang/zh-CN.js"></script>
    <script charset="utf-8" src="/lib/kindEditor/plugins/code/prettify.js"></script>
    <!-- web编辑器end -->
    <script type="text/javascript">
      $(function() {
        KindEditor.ready(function(K) {
          var editor1 = K.create('textarea[name="paperTitle"]', {
            cssPath: '/lib/JME_kind_editor/plugins/code/prettify.css',
            uploadJson: '/lib/JME_kind_editor/jsp/upload_json.jsp',
            allowFileManager: false,
            autoHeightMode: true,
            afterCreate: function() {
              var self = this;
              K.ctrl(document, 13, function() {
                self.sync();
                document.forms['example'].submit();
              });
              K.ctrl(self.edit.doc, 13, function() {
                self.sync();
                document.forms['example'].submit();
              });
            }
          });
          prettyPrint();
        });
      });

    </script>
  </body>

</html>